import re

# 打开文件并读取内容
with open('seat_and_lib', 'r') as file:
    # 读取文件的两行内容
    lines = [file.readline().strip() for _ in range(2)]

# 使用正则表达式匹配所需的数字
seat_key_match = re.search(r'"seatKey": "(\d+,\d+)"', lines[0])
lib_id_match = re.search(r'"libId": (\d+)', lines[1])

if seat_key_match and lib_id_match:
    seat_key = seat_key_match.group(1)
    lib_id = lib_id_match.group(1)

    print(f"seatKey: {seat_key}, libId: {lib_id}")
else:
    print("未找到匹配的内容")